import javax.swing.*;
import java.awt.*;

public class ButonRosu extends JMenuItem implements Command {
    /**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private JPanel panel;
    private Color color;
    
    public ButonRosu(JPanel panel,Color color){
        this.panel=panel;
        this.color=color;
    }

    public void execute(){
        this.panel.setBackground(this.color);
    }

}